﻿package com.eitb.reproductores {
	import flash.net.*;
	import flash.media.*;
	import flash.display.*;
	public class SimpleVideo extends Sprite implements IVistaVideo {
		private var video:Video;
		private var cVideo:IControladorVideo;
		
		public function SimpleVideo():void {
			this.initVideoPlayer();
		}
		
		public function initControlador(cVideo:IControladorVideo):void {
			this.cVideo = cVideo;
		}
		
		public function initVideoPlayer():void {
			this.video = new Video(this.width, this.height);
			this.addChild(this.video);
			this.video.deblocking=5;
			this.video.smoothing=true;
		}		
		
		// IVistaVideo
		public function setVisible(visible:Boolean):void {
			this.visible = visible;
		}
	
		public function move(x:Number, y:Number):void {
			this.x=x;
			this.y=y;
		}

		public function setSize(w:Number, h:Number):void {
			this.width=w;
			this.height=h;
		}
		
		public function attachNetStream(netStream:NetStream):void {
			this.video.attachNetStream(netStream);
		}
		// IVistaVideo
	}
}